1. Field of the Invention
The present invention relates-to an apparatus and a method for transforming a mathematical expression by using a computer, and a storage medium.
2. Description of the Related Art
In recent years, a throughput of a computer has been improved by leaps and bounds. With the improvement in throughput of a computer, a GUI (Graphical User Interface) by which an operator can visually grasp contents easily has been widespread as an interface between the operator and the computer. The GUI basically has such an advantage as that data created on a screen can be directly obtained by printout and the like. Therefore, a word processor software or a graphic drawing software has been recently produced by using the GUI.
With such a background, mathematical expressions are also created or edited by using the computer. Although only input of mathematical formulas or modification of inputted mathematical expressions are carried out in the prior art when creating numerical expressions, a software for automating transformation of mathematical expressions (for example, transposition of terms, development and others) has been produced in recent years. Such a technique is disclosed in, for example, U.S. Pat. No. 5,189,633 (Feb. 23, 1993) xe2x80x9cAPPARATUS AND METHOD FOR INTERACTIVELY MANIPULATING MATHEMATICAL EQUATIONS.xe2x80x9d Further, such a function is realized in a software xe2x80x9cGraphing Calculatorxe2x80x9d incorporated in a computer of Apple Computer Inc.
Here, a technique relating to a conventional mathematical expression transformation using a computer will be described with reference to FIGS. 11 and 12.
Referring to FIG. 11, inputting means 100 is, e.g., a keyboard, and indicating means 102 is, for example, a mouse 130 illustrated in FIG. 12. The inputting means 100 is mainly used when an operator inputs a mathematical formula in order to output mathematical expression data associated with the inputted mathematical formula. The indicating means 102 is mainly used when the operator indicates positions at which transformation is carried out, and it outputs the indicated mathematical expression which is a target of modification and a coordinate. Further, this means 102 outputs an indication signal for indicating the transformation processing. As shown in FIG. 12, a mouse 130 has a left button 132 and a right button 134. Indication signals such as xe2x80x9cLeft Downxe2x80x9d, xe2x80x9cLeft Upxe2x80x9d, xe2x80x9cRight Downxe2x80x9d and xe2x80x9cRight Upxe2x80x9d are outputted by pressing or releasing the left button 132 and the right button 134, respectively.
A computer 110 is, for example, a general personal computer. The computer 110 has processing means 112 and operating means 114.
The processing means 112 creates display data based on mathematical expression data outputted from the inputting means 100. Further, the operating means 114 produces a result of transformation mathematical expression based on the mathematical expression to be modified and the coordinate indicated by the indicating means 102.
Displaying means 120 is a display unit such as a CRT (cathode ray tube) and displays display data produced by the processing means 112.
The operation of the prior art technique having such a configuration will now be described hereinafter.
When the operator inputs a mathematical expression by the inputting means 100, the expression data is first outputted from the inputting means 100 to the processing means 112. The processing means 112 generates the display data from the inputted mathematical expression data and outputs it to the displaying means 120. The displaying means 120 displays the display data outputted from the processing means 112.
The operation when modifying (transforming) a specific position in the mathematical expression inputted by the operator will now be explained. In this case, the operator first specifies an element in the mathematical formula displayed on the display means 120 by operating the operating means 102. Moving a cursor of the mouse 130 onto the specified element and pressing the left button 132 cause the indicating means 102 to output the mathematical formula to be operated and the indication signal xe2x80x9cLeft Down.xe2x80x9d
When the mathematical expression to be operated and the indication signal xe2x80x9cLeft Downxe2x80x9d are inputted from the indicating means 102, the operating means 114 retains the mathematical formula to be operated (this retention of the mathematical formula will be referred to as xe2x80x9cgrabxe2x80x9d hereinafter).
Subsequently, when the operator moves the cursor of the mouse 130 while keeping pressing the left button 132, the indicating means 102 maintains output of the indication signal xe2x80x9cLeft Downxe2x80x9d and outputs a coordinate which sequentially varies in accordance with movement of the cursor.
Upon input of the coordinate which sequentially varies and the indication signal xe2x80x9cLeft Downxe2x80x9d from the indicating means 102, the operating means 114 confirms that the indication signal xe2x80x9cLeft Downxe2x80x9d is continuously inputted and moves the grabbed element (this processing will be referred to as xe2x80x9cdragxe2x80x9d hereinafter).
At last, when the operator drags to the coordinate for operation and thereafter releases the left button 132 on that coordinate, the indicating means 102 outputs the indication signal xe2x80x9cLeft Up.xe2x80x9d
Upon receiving the indication signal xe2x80x9cLeft Upxe2x80x9d from the indicating means 102, the operating means 114 lets dragged element down onto that coordinate (this processing will be referred to as xe2x80x9cdropxe2x80x9d hereinafter).
Moreover, at this time, the operating means 114 generates a transformation result of the mathematical formula based on the dropped mathematical expression to be operated and the coordinate for the operation and outputs it to the processing means 112. Here, the operating means 114 produces a transformation result in accordance with mathematical rules.
The processing means 112 then creates the display data based on the transformation result of the mathematical expression outputted from the operating means 114 and outputs it to the displaying means 120. The displaying means 120 displays the display data.
The input and modification (transformation) of the mathematical expression have been carried out in the prior art.
However, considering transformation of the mathematical expression by the operator, it is very difficult for the operator to completely recognize the drop position for obtaining a desired transformation result. In the conventional technique, it is hard for the operator to previously know what the result will be unless the drag-and-drop is once carried out.
As a countermeasure, there is an example contrived to display a transformation result during drag. However, this example always restricts a transformation result displayed during drag to one and loses many transformation possibilities. Additionally, since this example sequentially substitutes the mathematical expression originally displayed during drag in accordance with a transformation result, it is impossible to predict what will change and how during drag and there is no guarantee that the operator can carry out a desired transformation.
That is, there is such a problem as that a desired result can not be readily obtained when transforming the mathematical expression in the conventional technique relating to the mathematical expression transformation using a computer.
In view of the above-described drawbacks, it is an object of the present invention to provide an apparatus and a method which can obtain a result desired by an operator and display only a final result after transforming a mathematical expression an arbitrary number of times, thereby facilitating derivation of a result of mathematical expression transformation, and a storage medium.
According to an aspect of the present invention, there is provided with an apparatus for transforming a mathematical expression by using a computer, comprising: indicating means for outputting information relating to a position in the mathematical expression specified by a first indication of an operator and information relating to a part in the mathematical expression specified by a second indication of the operator; operating means for generating a plurality of proposed transformation results of the mathematical expression based on the information relating to a position and the information relating to a part outputted from the indicating means; and selecting means for selecting one from a plurality of the proposed transformation results.
In addition, the operating means generates different proposed transformation results as a plurality of the proposed transformation results if the information relating to a position outputted from the indicating means is different.
According to another aspect of the present invention, there is provided with the apparatus, further comprising: selection window controlling means for controlling display of a plurality of the proposed transformation results; selection window generating means for generating a selection window for displaying a plurality of the proposed transformation results under control of the selection window controlling means; and displaying means for displaying the selection window.
According to still another aspect of the present invention, there is provided with the apparatus, further comprising: inputting means for outputting mathematical expression data corresponding to an inputted mathematical expression in accordance with the operation by the operator; and processing means for generating display data corresponding to the mathematical expression data.
Further, the processing means generates display data based on the selection window to be outputted to the displaying means.
Furthermore, the operating means includes proposed mathematical expression transformation generating means for generating a plurality of the proposed transformation results; and proposed mathematical expression transformation holding means for storing and holding a plurality of the proposed transformation results generated by the proposed mathematical expression transformation generating means.
Moreover, the operating means includes a user-defined rule holding means for storing and holding rules for mathematical expression transformation defined by the operator.
According to still another aspect of the present invention, there is provided with the apparatus, further comprising: a storage medium for recording thereon the rules for mathematical expression transformation defined by the operator.
In addition, the user-defined rule holding means reads the rules for mathematical expression transformation from the storage medium and writes the held rules for mathematical expression transformation to the storage medium.
Further, the selecting means outputs a cancel signal to the processing means through the operating means when there is an indication of cancel by the operator, and the processing means deletes the display data based on the selection window when the cancel signal is inputted.
According to still another aspect of the present invention, there is provided with the apparatus, further comprising converting means for converting the mathematical data outputted from the inputting means and thereafter outputting the converted result to the processing means.
Furthermore, when a symbol or a character expression is inputted by the operator, the inputting means outputs symbol data corresponding to the symbol or character expression data corresponding to the character expression; the processing means generates indication data including the symbol data or the character expression data; and the operating means generates a plurality of proposed transformation results based on the indication data.
Moreover, the processing means has an interface for cooperation with another application and performs transmission/reception of data with respect to at least one of the inputting means, the indicating means and the selecting means through another application.
According to still another aspect of the present invention, there is provided with a method for transforming a mathematical expression using a computer, comprising the steps of: outputting information relating to a position in the mathematical expression specified by a first indication of an operator and information relating to a part in the mathematical expression specified by a second indication of the operator; generating a plurality of proposed transformation results of the mathematical expression based on the information relating to a position and the information relating to a part; and selecting one of a plurality of the proposed transformation results by an indication of the operator.
Additionally, when the information relating to a position is different, different proposed transformation results are generated as a plurality of the proposed transformation results.
According to still another aspect of the present invention, there is provided with a storage medium recording thereon a program enabling a computer to execute: processing for outputting information relating to a position in the mathematical expression specified by a first indication of an operator and information relating to a part in the mathematical expression specified by a second indication of the operator; processing for generating a plurality of proposed transformation results of the mathematical expression based on the information relating to a position and the information relating to a part; and processing for selecting one from a plurality of the proposed transformation results by an indication of the operator.
Further, when the information relating to a position is different, different proposed transformation results are generated as a plurality of the proposed transformation results.
According to still another aspect of the present invention, there is provided with a storage medium group for dividing the program into a plurality of parts and recording a plurality of the parts on a plurality of storage mediums.
According to still another aspect of the present invention, there is provided with a program embodied in electrical signals, said program enabling a computer to execute: processing for outputting information relating to a position in the mathematical expression specified by a first indication of an operator and information relating to a part in the mathematical expression specified by a second indication of the operator; processing for generating a plurality of proposed transformation results of a mathematical expression based on the information relating to a position and the information relating to a part; and processing for selecting one from a plurality of the proposed transformation results by an indication of the operator.
A first embodiment according to the present invention will now be described in detail hereinafter.
In FIG. 1, inputting means 10 is means used for inputting a mathematical expression by an operator. Indicating means 12 specifies an element in a mathematical expression to be operated and indicates a coordinate for the operation (for example, editing and transformation). Further, the indicating means 12 also outputs an indication signal (for example, xe2x80x9cLeft Downxe2x80x9d, xe2x80x9cLeft Upxe2x80x9d). Selecting means 14 selects specific selection information from selection information (for example, information indicating proposed transformations of a mathematical expression) displayed by displaying means 30 based on the operation by the operator and outputs it to selection window generating means 28 which will be described later.
A computer 20 includes processing means 22, operating means 24, selection window controlling means 26 and selection window generating means 28. The processing means 22 generates display data based on mathematical expression data outputted from the inputting means 10 and also produces display data based on selection window data outputted from the selection window generating means 28. The operating means 24 creates and holds a plurality of proposed transformation results of a mathematical expression based on the mathematical expression, which is a target of operation, the coordinate for the operation and the indication signal outputted from the indicating means 12. Here, the operating means 24 generates proposed results in accordance with mathematical rules or rules set by the operator.
Displaying means 30 displays display data outputted from the processing means 22.
In FIG. 1, when the operator operates the inputting means 10 to input a mathematical expression, the processing means 22 creates the display data based on mathematical expression data outputted from the inputting means 10 and outputs it to the displaying means 30. The displaying means 30 displays display data.
The operating means 24 performs grabbing by using a signal indicating a range of the mathematical expression outputted from the indicating means 12. When the range of the mathematical expression is specified, the processing for moving the range of the mathematical expression specified by the operation of the operator (drag) is executed. The operator operates the indicating means 12 to carry out this processing.
Here, the operating means 24 first outputs a drag start signal to the selection window controlling means 26. A plurality of proposed transformation results of the mathematical expression are created and held based on the mathematical expression and the coordinate for the operation outputted from the indicating means 12, and they are outputted to the selection window controlling means 26. Upon receiving the drag start signal, the selection window controlling means 26 outputs a control signal for controlling a window and a plurality of proposed transformation results of the mathematical expression outputted from the operating means 24 to the selection window generating means 28.
The selection window generating means 28 produces selection window data including selection information based on the control signal and a plurality of proposed mathematical expression transformation results outputted from the selection window controlling means 26.
When the operator operates the indicating means 12 to change a drag position (coordinate), the operating means 24 sequentially generates and holds a plurality of the proposed mathematical expression transformation results based on the mathematical expression and the sequentially varying coordinate outputted from the indicating means 12 and outputs them to the selection window controlling means 26. Here, the operating means 24 produces a plurality of proposed results in accordance with mathematical rules or rules set by the operator. The selection window controlling means 26 receives the proposed mathematical expression transformation results outputted from the operating means 24 and outputs the control signal together with this signal to the selection window generating means 28. The selection window generating means 28 generates selection window data including a plurality of the proposed mathematical expression transformation results. The processing means 22 produces the display data based on the selection window data generated by the selection window generating means 28, and the displaying means 30 displays the display data. This processing is repeated every time the operator operates the indicating means 12 to change the coordinate.
When the operator selects given selection information from the displayed selection information, the selecting means 14 outputs the selected selection information to the selection window generating means 28. This selection information is outputted to the operating means 24 through the selection window controlling means 26.
The operating means 24 extracts a selected transformation result from a plurality of proposed transformation results of the held mathematical expression in accordance with the inputted selection information and outputs it to the processing means 22. The processing means 22 generates the display data based on the transformation result outputted from the operating means 24 and outputs it to the displaying means 30. The displaying means 30 displays the display data.
Further, a computer-readable storage medium according to the present invention having a program for executing the processing by the computer recorded thereon corresponds to a storage medium 32 shown in FIG. 1. The program may be read by the computer to realize the above-described processing.
In this manner, the present invention can display proposed transformation results of the mathematical expression corresponding to the drag position during the drag operation by the operator and determine a transformation result of the mathematical expression by the drop operation.
Furthermore, in case of selecting a proposed transformation result of the mathematical expression, when the operator instructs cancel of the operation by the selecting means 14, the selecting means 14 outputs a cancel signal to the operating means 24 through the selection window generating means 28 and the selection window controlling means 26. When this cancel signal is inputted, the operating means 24 further outputs the cancel signal to the processing means 22. In response to this, the processing means 22 outputs the cancel signal to the display means 30. Upon receiving the cancel signal, the displaying means 30 stops displaying the display data based on the selection information.
In this way, the present invention can cancel the once-instructed operation for transforming the mathematical expression after confirming the proposed transformations.